package com.hundred.common;

import java.io.Serializable;


public class Result<T> implements Serializable{

	private static final long serialVersionUID = -5592371478635944394L;

	private boolean success = false; // 执行是否成功
    private String resultCode;
    protected String errorMassage;

	private T module; // 实际的返回结果

    public Result() {
    }

    public Result(T module) {
        this.module = module;
    }

    public static <T> Result<T> getResult(){
        return new Result<T>();
    }

    public boolean isSuccess() {
		return success;
	}

	public void setSuccess(boolean success) {
		this.success = success;
	}

	public String getResultCode() {
		return resultCode;
	}

	public void setResultCode(String resultCode) {
		this.resultCode = resultCode;
	}

	public String getErrorMassage() {
		return errorMassage;
	}

	public void setErrorMassage(String errorMassage) {
		this.errorMassage = errorMassage;
	}
	
    public T getModule() {
        return module;
    }

    public void setModule(T module) {
        this.module = module;
    }
    
}
